<template>
    <div class="shiti">
        <!--文字排序题-->
        <wenZhiPaiXu :Questions="QuestionDATA" :defAnswer="defAnswer" v-if="QuestionDATA.QuestionTypeCode=='QUE0138'"></wenZhiPaiXu>
        <!--图片排序题-->
        <tuPianPaiXu :Questions="QuestionDATA" :defAnswer="defAnswer" v-if="QuestionDATA.QuestionTypeCode=='QUE0139'"></tuPianPaiXu>
        <!--单选题-->
        <danXuan :Questions="QuestionDATA" :defAnswer="defAnswer" v-if="QuestionDATA.QuestionTypeCode=='QUE0020'"></danXuan>
        <!--判断题-->
        <panDuan :Questions="QuestionDATA" :defAnswer="defAnswer" v-if="QuestionDATA.QuestionTypeCode=='QUE0142'"></panDuan>
        <!--多选题-->
        <duoXuan :Questions="QuestionDATA" :defAnswer="defAnswer" v-if="QuestionDATA.QuestionTypeCode=='QUE0037'"></duoXuan>
        <!--主观题-->
        <zhuGuan :Questions="QuestionDATA" :defAnswer="defAnswer" v-if="QuestionDATA.QuestionTypeCode=='QUE0042'"></zhuGuan>
        <!--归类题-->
        <guiLei :Questions="QuestionDATA" :defAnswer="defAnswer" v-if="QuestionDATA.QuestionTypeCode=='QUE0049'"></guiLei>
        <!--文字连线题-->
        <!--图片连线题-->
        <lianXian :Questions="QuestionDATA" :defAnswer="defAnswer" v-if="QuestionDATA.QuestionTypeCode=='QUE0141' || QuestionDATA.QuestionTypeCode=='QUE0140'"></lianXian>
        <!--阅读理解-->
        <yueDuLiJie :Questions="QuestionDATA" :defAnswer="defAnswer" v-if="QuestionDATA.QuestionTypeCode=='QUE0008'"></yueDuLiJie>
        <!--听力判断题-->
        <listenPanDuan :Questions="QuestionDATA" :defAnswer="defAnswer" v-if="QuestionDATA.QuestionTypeCode=='QUE0143'"></listenPanDuan>
        <!--听力单项选择 -->
        <listenDanXuan :Questions="QuestionDATA" :defAnswer="defAnswer" v-if="QuestionDATA.QuestionTypeCode=='QUE0147'"></listenDanXuan>
        <!--听力图片连线题-->
        <!--听力文字连线题-->
        <listenTEXT :Questions="QuestionDATA" :defAnswer="defAnswer" v-if="QuestionDATA.QuestionTypeCode=='QUE0145' || QuestionDATA.QuestionTypeCode=='QUE0146' "></listenTEXT>
        <!--复合题-->
        <fuHe :Questions="QuestionDATA" :defAnswer="defAnswer" v-if="QuestionDATA.QuestionTypeCode=='QUE0043'"></fuHe>
        <stTool :ResourceID="QuestionDATA.child.ResourceID"></stTool>
        <stSubmitBtn :ResourceID="QuestionDATA.child.ResourceID"></stSubmitBtn>
    </div>
</template>
<script type="text/ecmascript-6">
import wenZhiPaiXu from './shiti/base/wenZhiPaiXu.vue'
import tuPianPaiXu from './shiti/base/tuPianPaiXu.vue'
import danXuan from './shiti/base/danXuan.vue'
import panDuan from './shiti/base/panDuan.vue'
import duoXuan from './shiti/base/duoXuan.vue'
import zhuGuan from './shiti/base/zhuGuan.vue'
import guiLei from './shiti/base/guiLei.vue'
import lianXian from './shiti/base/lianXian.vue'
import yueDuLiJie from './shiti/yueDuLiJie.vue'
import listenPanDuan from './shiti/listenPanDuan.vue'
import listenDanXuan from './shiti/listenDanXuan.vue'
import listenTEXT from './shiti/listenTEXT.vue'
import fuHe from './shiti/fuHe.vue'
import AnswerHelper from '../../assets/js/AnswerHelper.js'

export default {
    name: "shiti",
    props: ["QuestionDATA", "showModel","ExamParam"],
    data() {
        return {
            defAnswer:$.extend(true,{},this.ExamParam, {
                TestID:this.QuestionDATA.child.stem[0].TestID,
                StemID:this.QuestionDATA.child.stem[0].ID,
                CorrectAnswer: this.QuestionDATA.child.stem[0].CorrectAnswer,
                AnswerTimeJsCut: new Date().getTime(),
                Answer: '',
                StudentID:this.$store.state.userInfo.ID,
                QuestionTypeCode: this.QuestionDATA.child.stem[0].QuestionTypeCode
            })
        }
    },mounted(){
        AnswerHelper.SetExamSubmit(this.defAnswer)
    },
    components: {
        wenZhiPaiXu,
        danXuan,
        panDuan,
        duoXuan,
        zhuGuan,
        guiLei,
        tuPianPaiXu,
        lianXian,
        yueDuLiJie,
        listenPanDuan,
        listenDanXuan,
        listenTEXT,
        fuHe
    },
    methods: {
        closeModel() {
            this.showModel.show = false
        }
    }
}
</script>
<style lang="scss" rel="stylesheet/scss">
.shiti .divContent {
    background-image: url('../../assets/shitimaingb.png');
    background-repeat: repeat;
    width: 100%;
    height: 92%;
}

.shiti .divTitle {
    height: 8%;
    background-size: 100% 100%;
    background-image: url('../../assets/topbg.jpg');
    position: relative;
    box-shadow: 0 10px 20px 2px rgba(197, 208, 218, 0.8);
    h2 {
        font-size: 20px;
        line-height: 70px;
        color: white;
        padding: 0px 5px;
    }
}

.shiti .tigan {
    padding: 0px 5px;
    font-size: 36px;
    background: white;
    line-height: 2em;
    height: 89%;
    overflow: scroll;
}

.shiti .transit .tigan {
    padding: 0px 5px;
    font-size: 24px;
    background: white;
    line-height: 2em;
    overflow: scroll;
}

.shiti .TaskWarp .divMain .divContent .boxContent {
    position: absolute;
    width: 100%;
    height: 100%;
}

.shiti .TaskWarp .divMain .divContent .touchMove {
    background-color: #A7C8A2;
    width: 20%;
    border-radius: 10px;
    color: white;
    cursor: row-resize;
    font-size: 20px;
    height: 3%;
    text-align: center;
    margin: 0 auto;
    background-image: url('../../assets/sanheng.png');
    background-position: center;
    background-repeat: no-repeat;
    background-size: 15% 80%;
}

.shiti .boxContent .divItem {
    padding: 0 54px 0 25px !important;
    background-size: 100% 100%;
    background-image: url('../../assets/xianxiangbg.png');
    color: white;
    img {
        vertical-align: middle !important;
    }
}

.shiti .boxContent .divItem {
    .DanXuanOpts {
        padding-left: 8px;
    }
    .SerialNum {
        padding: 0 25px 0 0;
        border-right: 2px dashed #fff;
        font-weight: bold;
        display: inline-block;
        font-style: normal;
    }
}

.shiti .swiperCont .swiper-wrapper {
    width: 10000000px;
    height: 100%;
}

.shiti .swiperCont .swiper-wrapper .swiperItem {
    float: left;
    position: relative;
}
</style>
<style lang="scss" rel="stylesheet/scss" scoped>
.shiti {
    position: fixed;
    background: rgba(0, 0, 0, .62);
    height: 100%;
    width: 100%;
    left: 0;
    top: 0;
    z-index: 9999;
}
</style>